package sdk.webview.fmc.com.fmcsdk.util;

import android.app.Activity;
import android.content.Context;


import sdk.webview.fmc.com.fmcsdk.dialog.CenterCommDialog;
import sdk.webview.fmc.com.fmcsdk.interfaces.OnDialogSureListener;


public class DialogUtils {

    private static DialogUtils dialogManager;

    public static boolean dialogSSL;

    public static DialogUtils insertDialog() {
        if (dialogManager == null) {
            dialogManager = new DialogUtils();
        }
        return dialogManager;
    }


    public void dialogCenterComm(Context context, String title, String content, boolean isLogin, OnDialogSureListener onDialogSureListener) {
        if (context == null || ((Activity) (context)).isFinishing() || ((Activity) (context)).isDestroyed())
            return;
        CenterCommDialog centerCommDialog = new CenterCommDialog(context, content, "", isLogin,onDialogSureListener);
        centerCommDialog.show();
    }

}
